using Godot;
using System;

namespace TopDownGodot.Src.Multiplayer
{
    public partial class MultiplayerScene : Node
    {
        private readonly PackedScene _createServerScene = GD.Load<PackedScene>("res://scene/create_server_scene.tscn");
        private readonly PackedScene _connectServerScene = GD.Load<PackedScene>("res://scene/connect_server_scene.tscn");
        private readonly PackedScene _mainScene = GD.Load<PackedScene>("res://scene/main.tscn");

        public void OnCreateServerButton()
        {
            GetTree().ChangeSceneToPacked(_createServerScene);
        }

        public void OnConnectButton()
        {
            GetTree().ChangeSceneToPacked(_connectServerScene);
        }

        public void OnBackButton()
        {
            GetTree().ChangeSceneToPacked(_mainScene);
        }
    }
}
